from enum import Enum


class EventHandlerExeTypeEnum(Enum):

    SYNC_HANDLER  = "SyncHandler"
    ASYNC_IO_HANDLER  = "AsyncIOHandler"
    ASYNC_COMPUTE_HANDLER = "AsyncComputeHandler"


def get_event_handler_exe_type_by_value(value: str) -> EventHandlerExeTypeEnum | None:
    for item in EventHandlerExeTypeEnum:
        if item.value == value:
            return item
    return None